package com.axdoc.wallet.dao;

import java.sql.Timestamp;
import java.util.List;

import com.axdoc.wallet.entity.DoctorBalanceSubWallet;
import com.axdoc.wallet.entity.DoctorBalanceSubWalletRecords;
import com.axdoc.wallet.entity.DoctorWallet;

/**
 * 医生账户
 * 
 * @author sunzhaoli
 *
 */
public interface IDoctorWalletDao {
	/**
	 * 添加医生账户
	 * 
	 * @param doctorWallet
	 * @return
	 */
	public boolean addDoctorWallet(DoctorWallet doctorWallet);

	/**
	 * 添加医生余额子账户
	 * 
	 * @param doctorBalanceSubWallet
	 * @return
	 */
	public boolean addDoctorBalanceSubWallet(DoctorBalanceSubWallet doctorBalanceSubWallet);

	/**
	 * 根据docid查询医生账户信息
	 * 
	 * @param docid
	 * @return
	 */
	public DoctorWallet queryDoctorWalletByDocid(String docid);

	/**
	 * 根据docid查询医生余额子账户信息
	 * 
	 * @param docid
	 * @return
	 */
	public DoctorBalanceSubWallet queryDoctorBalanceSubWalletByDocid(String docid);

	/**
	 * 修改医生余额子账户信息
	 * 
	 * @param doctorBalanceSubWallet
	 * @return
	 */
	public boolean updateDoctorBalanceSubWallet(DoctorBalanceSubWallet doctorBalanceSubWallet);

	/**
	 * 添加医生余额子账户流水
	 * 
	 * @param balance
	 * @return
	 */
	public boolean addBalanceRecords(DoctorBalanceSubWalletRecords balance);

	/**
	 * 查询医生余额子账户流水
	 * 
	 * @param bizNo
	 *            业务单号
	 * @param startTime
	 *            开始时间
	 * @param endTime
	 *            结束时间
	 * @return
	 */
	public List<DoctorBalanceSubWalletRecords> queryBalanceRecords(String bizNo, Timestamp startTime,
			Timestamp endTime);
	/**
	 * 修改金额
	 * 
	 * @param id
	 * @param balance
	 * @return
	 */
	public boolean updateBalanceById(int id, int balance);
	/**
	 * 修改金额
	 * 
	 * @param id
	 * @param frozenBalance
	 * @return
	 */
	public boolean updateFrozenBalanceById(int id, int frozenBalance);

}
